

<extend name="Public:layout"/>
<block name="content">
<style type="text/css">

    .er{color:red;}
</style>
<div class="row-fluid sortable ui-sortable">
                <div class="box span12">
                    <div data-original-title="" class="box-header">
                        <h2><i class="halflings-icon white edit"></i><span class="break"></span>角色编辑</h2>
                        <div class="box-icon">
                            <a class="btn-setting" href="#"><i class="halflings-icon white wrench"></i></a>
                            <a class="btn-minimize" href="#"><i class="halflings-icon white chevron-up"></i></a>

                        </div>
                    </div>
                    <div class="box-content">
                         <form id="signupForm" enctype="multipart/form-data" class="form-horizontal" action="" method="post" >
                            <fieldset>

                              <div class="control-group">
                                    <label for="appendedInput" class="control-label">角色名称</label>
                                    <div class="controls">
                                      <div class="input-append">
                                        <input type="text" size="16" value="{$list.title}"  name="title">
                                      </div>

                                    </div>
                              </div>


                              <div class="control-group">
                                <label class="control-label">是否启用</label>
                                <div class="controls">
                                      <label class="radio">
                                        <input type="radio"  {$list['status']==1?'checked':''} value="1" id="optionsRadios1" name="status" required>启用
                                      </label>

                                      <label class="radio">
                                        <input type="radio" value="0"  {$list['status']==0?'checked':''} id="optionsRadios2" name="status">禁用
                                      </label>
                                </div>
                              </div>

              <div class="control-group">
                <label class="control-label">权限列表</label>
    <div class="box span8">


              <!-- {:print_r($data)} -->
              <foreach name="d" item="v">


                <div class="box-content">

                    <div class="control-group">
                       <label class="checkbox inline" style="float:left;">
                          <div class="checker" id="uniform-inlineCheckbox1"><span>
                          <input  value="" type="checkbox" class='ck'></span>
                          </div>
                        </label>
                        <label  class="control-label" style="width:100px;text-align: left;">{$v.name}</label><br/>

                        <div class="controls" style="margin-left: 0px;padding-left:0px;">
                          <foreach name="v.rule_name" key="k" item="vo">
                              <label class="checkbox inline" ">

                              <div class="checker" id="uniform-inlineCheckbox2" >
                                  <span >
                                    <input id="inline1" value="{$k}" {:in_array($k,$list['rules'])?'checked':''}  name="rules[]" type="checkbox">
                                  </span>
                                </div> {$vo}
                              </label>
                          </foreach>
                        </div>
                    </div>
                </div>

            </foreach>


        </div>
              </div>

                              <div class="form-actions">
                                <button class="btn btn-primary submit" type="submit">提交</button>

                              </div>
                            </fieldset>
                        </form>
                    </div>
                </div><!--/span-->

            </div>


</block>




<block name="js">

<script src="__PUBLIC__js/jquery.validate.min.js"></script>








<script type=text/javascript>



    </script>
</block>